- content_for(:title, 'Sources')
- content_for(:body_id, 'template_repo_flow')

= render '/shared/breadcrumbs', breadcrumbs: ['Manage',
                                               link_to('Dashboard', dashboard_index_path),
                                               yield(:title)]

%section.template-repos
  - if @template_repos
    %ul
      = render @template_repos

  = form_for @template_repo do |f|
    = f.label :name, 'New Source:'
    = f.text_field :name, placeholder: 'http://github.com/username/repository'
    = f.submit 'Save Source', class: 'button-positive'
    = link_to 'Cancel', '#', class: 'cancel', data: { toggle_class: 'expanded', toggle_target: 'section.template-repos', cancel_form: true }

  %a.button-add-positive{ data: { toggle: { class: 'expanded', target: 'section.template-repos' } } }
    Add a New Source
